#!/usr/bin/python
# -*- coding: utf-8 -*-
from pythonDFCF import t6


def initf():
    bksize = 5000
    while (bksize > 4200):
        count=1
        while(count<9):
            #print 'The count is:', count
            strutl="http://nufm.dfcfw.com/EM_Finance2014NumericApplication/JS.aspx?type=CT&cmd=C.BK0"+str(bksize)+"&sty=FCOIATA&sortType=C&sortRule=-1&page="+str(count)+"1&pageSize=20&js=var%20quote_123%3d{rank:[(x)],pages:(pc)}&token=7bc05d0d4c3c22ef9fca8c2a912d779c&jsName=quote_123&_g=0.555721483069983"
            count = count + 1
            if count==8 :
                bksize=bksize-1
            #print(strutl)
            try:
                t6.wjd(strutl)
                print("---->pass==bksize="+str(bksize))
            except Exception:
                print("---->error")
                #pass


initf()